﻿Public Class Tarea
    Inherits BasePersistencia

    Sub New()
        MyBase.Persistencia = EstadoPersistencia.INSERT
    End Sub

    Private _titulo As String
    Private _descripcion As String
    Private _usuario As Usuario
    Private _fecha As System.Nullable(Of Date) = DateTime.Now
    Private _fechaInicio As System.Nullable(Of Date) = DateTime.Now
    Private _horas As Integer
    Private _prioridad As Nivel
    Private _recursos As List(Of Recurso)
    Private _actividades As List(Of Actividad)
    Private _adjuntos As List(Of Archivo)
    Private _depente As Tarea

#Region "Propiedades"

    Public Property Titulo() As String
        Get
            Return _titulo
        End Get
        Set(ByVal value As String)
            _titulo = value
        End Set
    End Property

    Public Property Descripcion() As String
        Get
            Return _descripcion
        End Get
        Set(ByVal value As String)
            _descripcion = value
        End Set
    End Property

    Public Property Usuario() As Usuario
        Get
            Return _usuario
        End Get
        Set(ByVal value As Usuario)
            _usuario = value
        End Set
    End Property

    Public Property Fecha() As System.Nullable(Of Date)
        Get
            Return _fecha
        End Get
        Set(ByVal value As System.Nullable(Of Date))
            _fecha = value
        End Set
    End Property

    Public Property FechaInicio() As System.Nullable(Of Date)
        Get
            Return _fechaInicio
        End Get
        Set(ByVal value As System.Nullable(Of Date))
            _fechaInicio = value
        End Set
    End Property

    Public Property Horas() As Integer
        Get
            Return _horas
        End Get
        Set(ByVal value As Integer)
            _horas = value
        End Set
    End Property

    Public Property Prioridad() As Nivel
        Get
            Return _prioridad
        End Get
        Set(ByVal value As Nivel)
            _prioridad = value
        End Set
    End Property

    Public Property Recursos() As List(Of Recurso)
        Get
            Return _recursos
        End Get
        Set(ByVal value As List(Of Recurso))
            _recursos = value
        End Set
    End Property

    Public Property Actividades() As List(Of Actividad)
        Get
            Return _actividades
        End Get
        Set(ByVal value As List(Of Actividad))
            _actividades = value
        End Set
    End Property

    Public Property Adjuntos() As List(Of Archivo)
        Get
            Return _adjuntos
        End Get
        Set(ByVal value As List(Of Archivo))
            _adjuntos = value
        End Set
    End Property

    Public Property Depende() As Tarea
        Get
            Return _depente
        End Get
        Set(ByVal value As Tarea)
            _depente = value
        End Set
    End Property
#End Region

End Class
